import upyun
# #新建又拍云实例
up = upyun.UpYun('flies123adc', 'qwe123', '101tbBRjSUFAqwjXOcB3Uc0QpSkiN9ig')
# print('111111,',up)
# #上传文本
# up.put('/upyun_test.txt','abcdefghijklmnopqrst')
# # up.mkdir('/upyun_test/')101tbBRjSUFAqwjXOcB3Uc0QpSkiN9ig
#
# #文件流操作(节省内存)
# with open('./code.png','rb') as f:
#     #上传操作
#     res = up.put('/upyun_test.png',f,checksum=True)
# #目录操作  创建一个upyun_test目录
# up.mkdir('/upyun_test/')
#
# #移动文件
# #移动文件，移动到哪
# up.move('/upyun_test.png','/upyun_test/upyun_test.png')
#
# #复制文件
# up.copy('/upyun_test.txt','/upyun_test/upyun_test.txt')
#
# #断点续传 本地路径
# # with open('c:/test,mp4','rb') as f:
# #     res = up.put('/upyun_test/test.mp4',f,checksum=True,need_resume=True)
#
# #下载文件
# rest = up.get('/upyun_test/upyun_test.png')
##删除文件
# up.delete('/upyun_test/')